import { LoadingController } from 'ionic-angular';
import { Injectable } from '@angular/core';

@Injectable()
export class Loading {

    private loadBox: any;
    
    constructor(private loadingCtrl:LoadingController ) {}

    presentLoading():void {
        this.loadBox = this.loadingCtrl.create({
            content: "Loading..."
        }); 
        this.loadBox.present();
    }

    dismiss():void {
        this.loadBox.dismiss();
    }
}